Contents
Tardis version 2.0

Tardis is a utility for Windows 3.1 and 3.11 that synchronises your PCs clock to a central time Server.  Tardis requires a winsock v1.1 compliant TCP/IP stack,  Trumpet winsock, or Microsofts Wolverine for example.

A typical use of Tardis is to synchronise the PCs clock on starting a SLIP/PPP connection to an Internet provider (like demon in the UK).  Another is to have it running all the time in a LAN environment correcting the clock once an hour.

Tardis works connecting to the specified time Server and reading the (hopefully) correct time.  It uses the time protocol specified in RFC868

Tardis version 2.0 is shareware

Options

Where from:	Time server	Start minimized

How often:	Get time once then end	Get time every x mins

Setting the time:	Set time	Maximum correction allowed

Timezone information:	Timezone	Daylight savings rule

Buttons

Help	Invokes help.

Set	This button makes the settings shown in the dialog box active.

Reset	This resets the dialog box settings shown to the active values

About	Tells you about me.


If this is not set Tardis will not set the system time, useful if you dont initially trust the server you are connecting to.  It gives you a chance to see what kind of time it is going to give you first without setting your PCs time to 10:61 77 Jan. 1914 accidentally.


If this is set then Tardis will start as an icon.  This is useful if Tardis is being started from a Trumpet winsock login script.


Timezone

Select your timezone here.  A representative sample of cities is shown for each timezone to help you decide which one you are in if you dont know.  Note: Any TZ environment variable is completely ignored by Tardis.

Daylight savings time rule

Tardis will automatically switch from Summer to Winter time and back again at the correct times each year (make sure this is allowed by the Maximum correction allowed).  This option allows you to select which daylight savings rule applies for your time zone.  Almost every country does things differently.

Advanced configuration


This defines where you get your time from.


Time server

This setting is the name or address of the machine that knows the correct time.  The time server I use in the UK is 158.152.1.65 or hinge.demon.co.uk

Other good timeservers on the Internet are

tycho.usno.navy.mil	US Naval Observatory

time-A.timefreq.bldrdoc.gov	NIST Boulder CO.

The server machine will typically be a Unix™ machine, but a version of Tardis is available for Windows NT 3.1/3.5 that does the same job as this version but also acts a time server.  Available at all good NT archive sites.  (ftp.cica.indiana.edu, etc.)

The server address may be entered as a name, e.g. hinge.demon.co.uk, or as an Internet address e.g. 123.123.123.123.


This tells Tardis to die once it has got a time.  If it cant get one it will display the status and try again.  This is useful for setting the time when first establishing a dial-up Internet connection.


This tells Tardis to get and set the time every x minutes. It depends on how bad your clock is.  I use once every 60 minutes to keep mine in synch.  Once a day may be enough for you, but dont forget that your time server may be down for those few  crucial seconds.


Maximum correction allowed

Tardis validates the time received from the Server by checking that the amount of correction is not so far out that it must be wrong.  The Allowable correction setting specifies what is reasonable.  A setting of 3600 would allow  a correction of ±1 hour.

This is useful if your timezone is wrong or your time server has gone mad.

Note: If you want Tardis to automatically switch to or from daylight savings time you must allow the appropriate size of correction e.g. >3600 seconds.

A maximum correction of 0 means that any correction is allowed.


RFC868

Network Working Group	J. Postel - ISI

Request for Comments: 868	K. Harrenstien - SRI

May 1983

Time Protocol

This RFC specifies a standard for the ARPA Internet community.  Hosts on the ARPA Internet that choose to implement a Time Protocol are expected to adopt and implement this standard.

This protocol provides a site-independent, machine readable date and time.  The Time service sends back to the originating source the time in seconds since midnight on January first 1900.

One motivation arises from the fact that not all systems have a date/time clock, and all are subject to occasional human or machine error.  The use of time-servers makes it possible to quickly confirm or correct a system's idea of the time, by making a brief poll of several independent sites on the network.

This protocol may be used either above the Transmission Control Protocol (TCP) or above the User Datagram Protocol (UDP).

When used via TCP the time service works as follows:

   S: Listen on port 37 (45 octal).

   U: Connect to port 37.

   S: Send the time as a 32 bit binary number.

   U: Receive the time.

   U: Close the connection.

   S: Close the connection.

   The server listens for a connection on port 37.  When the connection is established, the server returns a 32-bit time value and closes the connection.  If the server is unable to determine the time at its site, it should either refuse the connection or close it without sending anything.

When used via UDP the time service works as follows:

   S: Listen on port 37 (45 octal).

   U: Send an empty datagram to port 37.

   S: Receive the empty datagram.

   S: Send a datagram containing the time as a 32 bit binary number.

   U: Receive the time datagram.

   The server listens for a datagram on port 37.  When a datagram arrives, the server returns a datagram containing the 32-bit time value.  If the server is unable to determine the time at its site, it should discard the arriving datagram and make no reply.

The Time

The time is the number of seconds since 00:00 (midnight) 1 January 1900 GMT, such that the time 1 is 12:00:01 am on 1 January 1900 GMT; this base will serve until the year 2036.

For example:

   the time  2,208,988,800 corresponds to 00:00  1 Jan 1970 GMT,

             2,398,291,200 corresponds to 00:00  1 Jan 1976 GMT,

             2,524,521,600 corresponds to 00:00  1 Jan 1980 GMT,

             2,629,584,000 corresponds to 00:00  1 May 1983 GMT,

        and -1,297,728,000 corresponds to 00:00 17 Nov 1858 GMT.


Advanced configuration

This section is for people who want to modify the timezone and daylight savings rules.  This might become necessary if the rules are changed in your region.  Not that uncommon unfortunately.  I have coded all the rules that I could find and I think that they are correct.

The timezones and descriptions are held in the tardis.ini file in your windows directory.

The section [Zones] holds the timezones.  These are held as

descriptive string=nnn

where nnn is the number of minutes west of GMT/UTC.  The descriptive string is purely descriptive it has no other significance.

The section [Rules] holds the daylight savings rules.  These are held as

descriptive string=s s s s s e e e e e

where s s s s s is the rule that dictates when daylight savings time starts and e e e e e when it ends.  The five numbers in each section have the following meaning.

The first number can have the following values.

0	The second number is the day of the month e.g. 25th

1-4	means the 1st-4th weekday of the month

5	means the last weekday however many there are.

The second is either the day of the month or the weekday where 0=sunday, 1=monday etc.

The third number is the month, 0 =January

The fourth is the hour of day the change is made (local standard time).

The fifth is the number of minutes added to local standard time to get local daylight time.

If the start of daylight savings time is after the end (as it is in the Australia) the time daylight savings is active is from the start date to the end of the year and from the beginning of the year to the end date.

Example

The entry

US/Canada/Mexico=1 0 3 1 60 5 0 9 1 0

means

Start of daylight time = 1st Sunday in April at 1a.m. 1 hour ahead

End of daylight time = Last Sunday in October at 1a.m. 0 hours ahead

I hope this all makes sense.  It isnt very pretty I know , but it does do the job.


Shareware

Copyright Notice

 1994 H.C. Mingham-Smith. (The author)

THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

Tardis for windows is Shareware.  This is a complete working version.  There are no annoying reminder screens about what it costs, and there are no disabled features.  If you continue to use it after evaluating it please send US$20 (or the rough equivalent in your local currency) to be sent by post to:

H. C. Mingham-Smith

33 Arthur Rd.

Wokingham,

Berkshire  RG11 2SS

England.

A cheque made payable to H.C. Mingham-Smith would be acceptable.

For sites where multiple copies are used I would request US$40 for the right to use on any machine at the site.

Please send e-mail regarding Tardis to tardis@kaska.demon.co.uk.